package com.air.antispider.stream.dataprocess.businessprocess

import scala.collection.mutable.ArrayBuffer


object IpOperation {

  /**
    * 判断指定ip是否为高频ip
    * @param remoteAddr
    * @param blackList
    * @return
    */
  def isFreIP(remoteAddr: String, blackList: ArrayBuffer[String]):Boolean = {
    //遍历黑名单每条数据，与指定ip匹配
    for (blackIP <- blackList) {
      if (remoteAddr.equals(blackIP)){
        return true
      }
    }
    false
  }

}
